<?php

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

Route::get('/', function () {
    return view('welcome',[]);
});
/** 路由可用路由组，但不要使用闭包，闭包无法生成缓存文件 */
Route::get('login', 'WebController@login');
Route::get('setData', 'WebController@setData');
Route::get('setUser', 'WebController@setAdmin');
Route::get('selectCourse', 'WebController@selectCoursePage');
Route::get('courseComment', 'WebController@courseCommentPage');
Route::get('courseResult', 'WebController@courseResultPage');
Route::get('courseCommentDetail', ['as'=>'index.courseCommentDetail',          'uses'=>'WebController@courseCommentDetail']);

Route::group(['prefix'=>'admin'],function() {
    Route::get('uploadExcel',   ['as'=>'admin.uploadExcel',     'uses'=>'WebController@uploadExcelPage']);
    Route::get('home',          ['as'=>'admin.home',            'uses'=>'WebController@home']);
    Route::get('UserList',      ['as'=>'admin.UserList',        'uses'=>'WebController@UserList']);
    Route::get('TeacherList',   ['as'=>'admin.TeacherList',     'uses'=>'WebController@TeacherList']);
    Route::get('courseList',    ['as'=>'admin.courseList',      'uses'=>'WebController@courseList']);
    Route::get('courseScheduleList',   ['as'=>'admin.courseScheduleList',     'uses'=>'WebController@courseScheduleList']);
    Route::get('exportSelectData',   ['as'=>'admin.exportSelectData',     'uses'=>'WebController@exportSelectData']);
    Route::get('exportCommentData',   ['as'=>'admin.exportCommentData',     'uses'=>'WebController@exportCommentData']);
});
/** 路由可用路由组，但不要使用闭包，闭包无法生成缓存文件 */
/** 路由可用路由组，但不要使用闭包，闭包无法生成缓存文件 */

